-- 8-1开启事务执行插入学生信息和修改学生信息操作
-- 开启事务
BEGIN;
-- 执行SQL语句
insert into t_student(id,student_name,age,gender,birthday,classID,begin_year) VALUES(3006,'赵丽丽',20,'女','2003-09-18',3,'2023');
update t_student set birthday='2003-02-02' where student_name='赵丽丽';
insert into t_course1(exam_score,studentID,courseID) values(83,3006,1);
-- 提交事务
COMMIT
-- 回滚事务
ROLLBACK;